package com.ct.R.Result.ResultEnum;

import com.ct.R.IResultCodeInterface;
import lombok.Getter;

@Getter
public enum ResultCodeEnum implements IResultCodeInterface {
    SUCCESS(20000, "SUCCESS", "成功"),
    FAIL(40000, "FAIL", "失败"),
    SERVER_ERROR(50000, "SERVER_ERROR", "服务错误"),
    LIMITE_SERVER_ERROR(50008, "SERVER_ERROR", "客官你慢点，请稍后在试一试!!!"),
    REQUESTS_ARE_TOO_FREQUENT(40006, "SERVER_ERROR", "操作过于频繁，请稍后再试"),
    ACCESS_DENIED(40003, "ACCESS_DENIED", "无权访问，必须携带Token"),
    CAPTCHA_ERROR(40004, "CAPTCHA_ERROR", "验证码生成失"),
    ;

    private Integer code;
    private String codeDesc;
    private String msg;

    ResultCodeEnum(Integer code, String codeDesc, String msg){
        this.code = code;
        this.codeDesc = codeDesc;
        this.msg = msg;
    }
}
